package com.daisuxia.payRoute;

import java.io.IOException;
import java.util.HashMap;
import java.util.Map;

import com.daisuxia.web.pojo.OutOrders;

/**
 * Created by dhl on 2017/5/19.
 */
//代扣查询
public class PayQueryRoute {

	//支付管理者
	private static Map payMap = new HashMap();

	static {
		payMap.put(OutOrders.TYPE_BAOFOO,new BaofooPayQuery());
		payMap.put(OutOrders.TYPE_RONGBAO,new RongBaoCollQuery());
	}
	//查询订单支付状态

	/**
	 * map.get("orderNo").toString();//订单号
	 * map.get("payDate").toString();//订单支付时间 yyyyMMDDHHmmss
	 * map.get("payCutType").toString();//订单支付类型
	 * @param map
	 * @return
	 * @throws Exception 
	 */
	public static Map queryTransPay(Map map) throws Exception {

		return ((IPayQuery)payMap.get(map.get("payCutType").toString())).handleOrder(map);
	}

}
